package yzserver.sx4a.dao.ibatis;

import com.sitech.ibnms.core.BaseIbnmsDao;
import yzserver.sx4a.dao.IPositionTypeDao;
import yzserver.sx4a.domain.PositionTypeDomain;

import java.util.HashMap;
import java.util.List;

public class PositionTypeDaoImpl extends BaseIbnmsDao implements IPositionTypeDao {


    @Override
    public PositionTypeDomain selPositionType(String positionTypeid) {
        HashMap map = new HashMap();
        map.put("positionTypeid",positionTypeid);
        return (PositionTypeDomain)querySingle("shanxi_selPositionType",map);
    }

    @Override
    public void addPositionType(PositionTypeDomain positionType) throws Exception {
        insert("shanxi_addPositionType",positionType);
    }

    @Override
    public void updPositionType(PositionTypeDomain positionType) throws Exception {
        update("shanxi_updPositionType",positionType);
    }

    @Override
    public void delPositionType(String positionTypeid) throws Exception {
        HashMap map = new HashMap();
        map.put("positionTypeid",positionTypeid);
        delete("shanxi_delPositionType",map);
    }

    @Override
    public List<PositionTypeDomain> selAllPositionType(String positionTypeid) {
        HashMap map = new HashMap();
        map.put("positionTypeid",positionTypeid);
        return (List<PositionTypeDomain>)query("shanxi_selAllPositionType", map);
    }
}
